/**
 * 
 */
package wzw.util;

import java.util.ResourceBundle;

/**
 *  I18nUtils, I18nUtil 都是wzw.util下的国际化类。
 * @author Zeven
 *  
 */
public class I18nUtil {

	private static String I18n_Language_Name = "Language";

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		System.out.println( getBundleString(null, I18nUtil.class,"" ));

	}

	//wzw.util.I18nUtil.name
	public static String getBundleString(ResourceBundle bundle,
			Class<?> clazz, String str) {
		return getBundleString(bundle, clazz.getName(), str);
	}

	//wzw.util.I18nUtil.name
	public static String getBundleString(ResourceBundle bundle,
			String className, String str) {
		return bundle.getString(className + "." + str);
	}
	

	//wzw.util.I18nUtil.name
	public static String getBundleString( Class<?> clazz, String str) {
		return getBundleString( clazz.getName(), str);
	}

	//wzw.util.I18nUtil.name
	public static String getBundleString( String className, String str) {
		ResourceBundle bundle = I18nUtils.getBundle(I18n_Language_Name );
		return getBundleString(bundle, className ,str);
	}
	
}
